<template>
  <div>
    <!-- <div v-if="type==404"> -->
    <defalut-error-page :errorType="type"></defalut-error-page>
    <!-- </div> -->
  </div>
</template>

<script>
import DefalutErrorPage from '@/components/Exception/DefalutErrorPage'
import { useRouter } from "vue-router";
//错误类型待扩展
const errType = [401,402,403,404,503];
export default {
  components:{
    DefalutErrorPage
  },
  setup(){
    const route = useRouter();
    var type = route.currentRoute.value.query.type;
    if(!errType.find(x=>x==type)){
      type = 404;
    }
    return{
      type
    }
  },
  mounted(){
    
  },
  methods:{
    
  }
}
</script>

<style>
</style>